import axios from './axios'

//考勤设备列表
export function getEquipList(params) {
    const url = '/ms/api/equip/list'
    return axios.get(url, params)
}
// 添加考勤设备
export function getEquipAdd(params) {
    const url = '/ms/api/equip/add'
    return axios.post(url, params)
}
// 获取考勤设备详情
export function getEquipDetails(params) {
    const url = '/ms/api/equip/detail'
    return axios.get(url, params)
}
// 考勤设备修改
export function getEquipEdit(params) {
    const url = '/ms/api/equip/edit'
    return axios.post(url, params)
}
// 考勤设备退场
export function getEquipOuter(params) {
    const url = '/ms/api/equip/outer/'
    return axios.post(url + params)
}
// 考勤设备进场
export function getEquipEnter(params) {
    const url = '/ms/api/equip/enter/'
    return axios.post(url + params)
}
// 考勤设备绑定
export function getEquipBind(params) {
    const url = '/ms/api/equip/bind'
    return axios.post(url , params)
}
// 考勤设备解除绑定
export function getEquipUnBind(params) {
    const url = '/ms/api/equip/unbind/'
    return axios.post(url + params)
}
// 考勤设备信息解除绑定
export function getEquipUnDel(params) {
    const url = '/ms/api/equip/del/'
    return axios.post(url + params)
}
//上传考勤设备信息图片到服务器
export function getEqipUploadImg(params) {
    const url = '/ms/api/equip/upload'
    return axios.post(url, params)
}
// 获取考勤设备信息二维码
export function getEquipGetQr(params) {
    const url = '/ms/api/equip/getQr'
    return axios.get(url, params)
}

// 获取设备考勤列表
export function getEquipAttendList(params) {
    const url = '/ms/api/equip/attend/list'
    return axios.get(url, params)
}
// 获取设备考勤出勤记录
export function getEquipAttendLog(params) {
    const url = '/ms/api/equip/attend/log'
    return axios.get(url, params)
}

// 获取设备考勤日报
export function getEquipDayReportList(params) {
    const url = '/ms/api/equip/dayReport/list'
    return axios.get(url, params)
}

// 获取设备考勤日报详情
export function getEquipDayReportDetails(params) {
    const url = '/ms/api/equip/dayReport/detail'
    return axios.get(url, params)
}

//获取考勤电子围栏列表
export function getEquipFencetList(params) {
    const url = '/ms/api/equip/fence/list'
    return axios.get(url, params)
}
//添加考勤电子围栏
export function getEquipFencetAdd(params) {
    const url = '/ms/api/equip/fence/add'
    return axios.post(url, params)
}
//删除考勤电子围栏
export function getEquipFencetDel(params) {
    const url = '/ms/api/equip/fence/del/'
    return axios.post(url+ params)
}
//获取考勤设备列表
export function getEquipEmpListAll(params) {
    const url = '/ms/api/equip/list'
    return axios.get(url,params)
}
//获取电子围栏绑定考勤设备列表
export function getEquipEmpList(params) {
    const url = '/ms/api/equip/fence/equip/list'
    return axios.get(url,params)
}
//添加电子围栏绑定考勤设备列表
export function getEquipEmpAdd(params) {
    const url = '/ms/api/equip/fence/equip/add'
    return axios.post(url,params)
}

//报警设置规则列表
export function getEquipRuleList(params) {
    const url = '/ms/api/equip/warn/rule/list'
    return axios.get(url, params)
}
//新增报警规则
export function getEquipRuleAdd(params) {
    const url = '/ms/api/equip/warn/rule/add'
    return axios.post(url, params)
}
//编辑报警规则
export function getEquipRuleEdit(params) {
    const url = '/ms/api/equip/warn/rule/edit'
    return axios.post(url, params)
}
//启用禁用报警规则
export function getEquipRuleEnable(params) {
    const url = '/ms/api/equip/warn/rule/enable'
    return axios.post(url, params)
}
//删除报警规则
export function getEquipRuleDel(params) {
    const url = '/ms/api/equip/warn/rule/del/'
    return axios.post(url+params)
}
//规则已设置的考勤设备列表
export function getEquipObjectAddList(params) {
    const url = '/ms/api/equip/warn/object/list'
    return axios.get(url,params)
}
//所有考勤设备
export function getEquipObjectList(params) {
    const url = '/ms/api/equip/warn/getEquipList'
    return axios.get(url,params)
}
//设置报警规则报警对象
export function getEquipObjectAdd(params) {
    const url = '/ms/api/equip/warn/object/add'
    return axios.post(url,params)
}
//设置报警规则生效时间
export function getEquipSetTime(params) {
    const url = '/ms/api/equip/warn/setTime'
    return axios.post(url,params)
}
//已有报警接收人和方式
export function getEquipUserList(params) {
    const url = '/ms/api/equip/warn/user/list'
    return axios.get(url,params)
}
//设置报警接收人和接收方式
export function getEquipUserAdd(params) {
    const url = '/ms/api/equip/warn/user/add'
    return axios.post(url,params)
}
//报警记录列表
export function getEquipRecordList(params) {
    const url = '/ms/api/equip/warn/record/list'
    return axios.get(url,params)
}
//报警详情
export function getEquipRecordDetail(params) {
    const url = '/ms/api/equip/warn/record/detail'
    return axios.get(url,params)
}
//处理报警
export function getEquipRecordHandle(params) {
    const url = '/ms/api/equip/warn/record/handle'
    return axios.post(url,params)
}
//获取考勤轨迹
export function getEquipAttendGpsList(params) {
    const url = '/ms/api/equip/attend/gps/list'
    return axios.get(url,params)
}
//获取考勤轨迹
export function getFenceWorkingArea(params) {
    const url = '/ms/api/equip/fence/listByEquipId'
    return axios.get(url,params)
}

//获取考勤报表
export function getEquipAttendReportList(params) {
    const url = '/ms/api/equip/attend/report'
    return axios.get(url,params)
}
//考勤报表导出
export function getEquipAttendReportExp(params) {
    const url = '/ms/api/equip/attend/report/export'
    return axios.get(url,params)
}

//设备信息导出
export function getEquipExport(params) {
    const url = '/ms/api/equip/export'
    return axios.get(url,params)
}


//查询可选择的设备类别
export function getEquipType(params) {
    const url = '/ms/api/equip/index/getEquipType'
    return axios.get(url,params)
}

/**
 * 
 * 考勤企业级
 */
// 企业级查询所属公司下项目
export function getCompanyIndexProjectList(params) {
    const url = '/ms/api/equip/company/index/projectList'
    return axios.get(url,params)
}
// 企业级统计项目下设备信息
export function getCompanyIndexAttend(params) {
    const url = '/ms/api/equip/company/index/attend'
    return axios.get(url,params)
}
// 企业级出勤分析
export function getCompanyAttendList(params) {
    const url = '/ms/api/equip/company/attend/list'
    return axios.get(url,params)
}
// 企业级设备信息
export function getCompanyMachList(params) {
    const url = '/ms/api/equip/company/list'
    return axios.get(url,params)
}
// 企业级统计考勤设备
export function getCompanyMachAttendNum(params) {
    const url = '/ms/api/equip/company/attendNum'
    return axios.get(url,params)
}
// 企业级预警中心
export function getCompanyWarnList(params) {
    const url = '/ms/api/equip/company/warn/list'
    return axios.get(url,params)
}
// 设备调动列表
export function getTransferList(params) {
    const url = '/ms/api/equip/transferList'
    return axios.get(url,params)
}
// 设备调动
export function getCompanyTransfer(params) {
    const url = '/ms/api/equip/company/transfer'
    return axios.post(url,params)
}
// 电子围栏列表(不分页)
export function getEquipFenceList(params) {
    const url = '/ms/api/equip/fence/list'
    return axios.get(url,params)
}






